package lanqiao._13th;

import com.sun.org.apache.xerces.internal.impl.xs.SchemaNamespaceSupport;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Objects;
import java.util.Scanner;
import java.util.StringTokenizer;

/**
 * @author 挚爱之夕
 * @version 1.0
 * @implSpec lanqiao._13th
 * @since 2022 - 10 - 08 - 16:56
 */
public class BufferedReaderTest {
    private final BufferedReader bufferedReader;
    //字符串解析器
    private StringTokenizer stringTokenizer = new StringTokenizer("");
    public BufferedReaderTest() {
        this.bufferedReader = new BufferedReader(new InputStreamReader(System.in));
    }
    public String nextLine() throws IOException {
        return bufferedReader.readLine();
    }
    public int nextInt() throws IOException {
        return Integer.parseInt(next());
    }
    public double nextDouble() throws IOException {
        return Double.parseDouble(next());
    }

    public String next() throws IOException {
        if (!stringTokenizer.hasMoreElements()) {
            stringTokenizer = new StringTokenizer(nextLine());
        }
        return stringTokenizer.nextToken();
    }

    public static void main(String[] args) throws IOException {
        BufferedReaderTest reader = new BufferedReaderTest();
//        String str = reader.nextLine();
//        System.out.println(str);
//        System.out.println("-------------");
//        System.out.println(reader.next());
//        System.out.println("-------------");
//        System.out.println(reader.nextInt());
//        System.out.println(reader.nextDouble());
//        Scanner scanner = new Scanner(System.in);
//        for(int i = 0; i < 5; i++){
//            System.out.println(scanner.nextInt());
//        }
        while(true){
            String next = reader.next();
            if("quit".equals(next)){
                break;
            }
            System.out.println(next);
        }
    }
}
